projects
/
ostree.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ad08799
)
os-init: also create a symlink for /var/lock
author
Cosimo Cecchi
<cosimo@endlessm.com>
Wed, 12 Feb 2014 01:15:19 +0000
(17:15 -0800)
committer
Cosimo Cecchi
<cosimo@endlessm.com>
Wed, 12 Feb 2014 22:05:13 +0000
(14:05 -0800)
After creating one for /var/run. This is needed at least on Debian
systems.
src/ostree/ot-admin-builtin-os-init.c
patch
|
blob
|
history
diff --git
a/src/ostree/ot-admin-builtin-os-init.c
b/src/ostree/ot-admin-builtin-os-init.c
index e15150603dbfc3d21d40693ca9ab656e49bd20db..38c2187e6d88252c46de026e8176586077cff359 100644
(file)
--- a/
src/ostree/ot-admin-builtin-os-init.c
+++ b/
src/ostree/ot-admin-builtin-os-init.c
@@
-96,6
+96,16
@@
ot_admin_builtin_os_init (int argc, char **argv, OstreeSysroot *sysroot, GCancel
}
}
+ dir = ot_gfile_get_child_build_path (deploy_dir, "var", "lock", NULL);
+ if (!g_file_test (gs_file_get_path_cached (dir), G_FILE_TEST_IS_SYMLINK))
+ {
+ if (symlink ("../run/lock", gs_file_get_path_cached (dir)) < 0)
+ {
+ ot_util_set_error_from_errno (error, errno);
+ goto out;
+ }
+ }
+
g_print ("%s initialized as OSTree root\n", gs_file_get_path_cached (deploy_dir));
ret = TRUE;